package java;

class Derived extends Base {
    int extraValue;
 
    public Derived() {
        super(); // Calls the default constructor of Base
        System.out.println("Derived default constructor");
    }
 
    public Derived(int value, int extraValue) {
        super(value); // Calls the parameterized constructor of Base
        this.extraValue = extraValue;
        System.out.println("Derived parameterized constructor with values: " + value + ", " + extraValue);
    }
 
    @Override
    public String toString() {
        return "Base value: " + value + ", Extra value: " + extraValue;
    }
}
